#include "widget.h"
#include "ui_widget.h"
#include "teacher.h"
#include "student.h"
#include <QPushButton>
Widget::Widget(QWidget *parent)
    : QWidget(parent)
    , ui(new Ui::Widget)
{
    ui->setupUi(this);
    th = new teacher(this);
    st = new student(this);

    QPushButton *button = new QPushButton("上课",this);
    button->move(100,100);
    connect(th,&teacher::teacher_signal,st,&student::student_slots);
    EmitSignal();
}

Widget::~Widget()
{
    delete ui;
}

void Widget::EmitSignal()
{
    emit th->teacher_signal();
}


